
import Qt 4.7


Rectangle {
    id: window
    
    width: 300; height: 500
    color: "#3E606F"

    XmlListModel {
	id: xmlModel
	source: "http://manu42.local:8084/LocalModel/findFiles.jsp?dir=/home/emugwaneza/Vidéos&filter=.avi"
	query: "/fichiers/fic"
	XmlRole { name: "name"; query: "name/string()" }
	XmlRole { name: "isDir"; query: "isDir/string()" }
	XmlRole { name: "icon"; query: "icon/string()" }
	XmlRole { name: "sPath"; query: "exactPath/string()" }
    }

    ListView {
	    id: list1
	    //y: activeFocus ? 10 : 40; width: 300 ; height: 800
	    y:0
	    focus: true
            model:xmlModel
            anchors.fill: parent
	    delegate: ListViewDelegate {}
	    //spacing:20
	    /*Behavior on y {
		NumberAnimation { duration: 600; easing.type: Easing.OutQuint }
	    }*/
	    
	    /*Keys.onPressed: {
		if (event.key == Qt.Key_Return) {
		    console.log("selected ############:"  + currentIndex );
		    event.accepted = true;
		}
	    }*/
	}

	/*states: 
		State {
			  name: "avancer";
			  PropertyChanges { target: list1; x:1000  }
		      }
	    
	    transitions: Transition {
		NumberAnimation { properties: "x,y"; duration: 2000 }
	    }*/
        
  
    
   
        
}
